import { PrismaClient } from "@prisma/client";
import { injectable, inject } from "inversify";

@injectable() //注入器，可以注入到其他类中
export class PrismaDB {
  prisma: PrismaClient;
  constructor(@inject("PrismaClient") PrismaClient: () => PrismaClient) {
    this.prisma = PrismaClient();
    console.log("prisma db init");
  }
}
